Distance measuring apparatus

ABSTRACT

The present invention relates to a distance measuring apparatus including an imaging device and a calculation unit calculating a distance to a subject on the basis of an electrical signal. The imaging device includes a signal acquisition unit that acquires a first electrical signal based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction; a second electrical signal based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction; and a third electrical signal based on a beam that has passed through a region eccentric from the first region in the direction opposite to the predetermined direction. The calculation unit performs a signal correction process for generating a first corrected signal and a distance calculation process for calculating the distance.

TECHNICAL FIELD

The present invention relates to a distance measuring apparatus, and in particularly, to a distance measuring apparatus for use in a digital still camera, a digital video camera, and so on.

BACKGROUND ART

A phase-contrast distance measuring technique is known as a distance measuring technique applicable to digital still cameras and video cameras.

PTL 1 discloses a solid-state imaging device in which some of pixels have a ranging function using a phase contrast method. The individual pixels have light receiving portions each including a microlens and a photoelectric conversion section. The light receiving portions have the characteristic of having sensitivity to a beam that is incident thereon at a small angle range through the microlens by guiding light incident at a specific angle to the photoelectric conversion sections. With this configuration, beams that have passed through partial regions on the pupil of the image-forming optical system are detected. Two images generated from the beams that have passed through different regions on the pupil of the camera lens are acquired by different light receiving portions. The distance between the two images is estimated, and the defocusing amount is calculated by triangulation using a stereo image to perform ranging.

This method does not need to move the lens to measure the range, in contrast to the conventional contrast method, thus allowing high-speed high-accuracy ranging.

The signals acquired by the light receiving portions of the pixels can be used as imaging signals for generating an image, thus allowing imaging and ranging at the same time.

PTL 2 discloses a focus detection apparatus equipped with an imaging device having a pair of pixel groups that receive beams that have passed through different pupil regions of an image-capturing optical system and output a first image signal and a second image signal, respectively.

The focus detection apparatus includes a calculation unit that subtracts a value obtained by multiplying a second image signal by a second factor from a value obtained by multiplying a first image signal by a first factor to generate a first correct image signal and that subtracts a value obtained by multiplying a first image signal by a fourth factor from a value obtained by multiplying a second image signal by a third factor to generate a second correct image signal; and a focus detection unit that determines the defocusing amount on the basis of the phase difference between the first and second correct image signals.

CITATION LIST Patent Literature

PTL 1 Japanese Patent Laid-Open No. 2002-314062 PTL 2 U.S. Pat. No. 8,159,599

SUMMARY OF INVENTION Technical Problem

With the configuration disclosed in PTL 1, the light receiving portions are low-sensitivity light receiving portions having sensitivity only to beams that enter in a relatively narrow angle range. Ranging a low-luminance subject with such light receiving portions causes low signal intensity and an insufficient S/N ratio, thus making it difficult to achieve high-accuracy ranging.

In contrast, using high-sensitivity light receiving portions having sensitivity to beams that enter in a wide angle range increases the signal intensity and improves the S/N ratio of the signals. These light receiving portions detect beams that have passed through a wide region of the pupil. This makes pupil division indefinite and the base length short, thus making it difficult to achieve high-accuracy ranging.

The configuration disclosed in PTL 2 may have room for improvement in focusing accuracy for a low-luminance subject, although the configuration increases the focusing accuracy with a simple calculation.

In consideration of the above problem, the present invention provides a distance measuring apparatus capable of measuring a distance to a low-luminance subject with high accuracy by using high-sensitivity light receiving portions that causes indefinite pupil division.

Solution to Problem

A distance measuring apparatus according to an aspect of the present invention includes an optical system forming an image of a subject; an imaging device acquiring an electrical signal from a beam that has passed through an exit pupil of the optical system; and a calculation unit calculating a distance to the subject on the basis of the electrical signal. The imaging device includes a signal acquisition unit that acquires, on a plurality of locations on the imaging device, a first electrical signal mainly based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction, a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction, and a third electrical signal different from the second electrical signal on the basis of a beam that has passed through a region eccentric from the first region in the direction opposite to the predetermined direction. The calculation unit performs a signal correction process for generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion and a distance calculation process for calculating the distance by using the first corrected signal.

Further features of the present invention will become apparent from the following description of exemplary embodiments with reference to the attached drawings.

Advantageous Effects of Invention

According to an embodiment of the present invention, a distance measuring apparatus capable of measuring a distance to a low-luminance subject with high accuracy can be achieved.

BRIEF DESCRIPTION OF DRAWINGS

FIG. 1A is a cross-sectional view showing, in outline, a distance measuring apparatus according to an embodiment of the present invention;

FIG. 1B is a schematic diagram illustrating an example of an imaging device;

FIG. 1C is a schematic diagram illustrating an example of the overall configuration of the distance measuring apparatus;

FIG. 2A is a graph showing the characteristics of the distance measuring apparatus;

FIG. 2B is a diagram of an exit pupil according to an embodiment of the present invention;

FIG. 3 is a flowchart for the distance measuring apparatus according to an embodiment of the present invention;

FIG. 4A is a graph showing the angle characteristics of light receiving portions;

FIG. 4B is a graph showing the angle characteristics of imaginary light receiving portions;

FIG. 4C is a diagram illustrating pupil divided regions and the centers of gravity of the pupils;

FIG. 5 is a flowchart for the distance measuring apparatus according to an embodiment of the present invention;

FIG. 6 is a cross-sectional view showing, in outline, an imaging device of a distance measuring apparatus according to a first embodiment of the present invention;

FIG. 7A is a diagram illustrating an example of the imaging device of the distance measuring apparatus according to the first embodiment of the present invention;

FIG. 7B is a cross-sectional view showing, in outline, the imaging device of the distance measuring apparatus according to the first embodiment of the present invention;

FIG. 8 is a cross-sectional view showing, in outline, an imaging device of the distance measuring apparatus according to the first embodiment of the present invention;

FIG. 9A is a diagram illustrating an example of an imaging device of a distance measuring apparatus according to a second embodiment of the present invention;

FIG. 9B is a graph showing the angle characteristics of the light receiving portions;

FIG. 9C is a diagram showing pupil divided regions on the exit pupil; and

FIG. 10 is a diagram illustrating an example of an imaging device of a distance measuring apparatus according to a third embodiment of the present invention.

DESCRIPTION OF EMBODIMENTS

Basic Configuration

Referring to FIGS. 1A to 1C and FIGS. 2A and 2B, a distance measuring apparatus 100 according to an embodiment of the present invention will be described.

The distance measuring apparatus 100 according to an embodiment of the present invention includes an optical system 101 that forms an image of a subject, an imaging device 102 that acquires an electrical signal by using a beam that has passed through an exit pupil of the optical system 101, and a calculation unit that calculates a distance to the subject on the basis of the electrical signal.

FIG. 1A is a schematic diagram that mainly illustrates the image-forming optical system 101 and the imaging device 102 constituting the distance measuring apparatus 100 according to an embodiment of the present invention. FIG. 1B is a schematic diagram illustrating an example of the imaging device 102. FIG. 1C is a schematic diagram illustrating an example of the overall configuration of the distance measuring apparatus 100 according to an embodiment of the present invention.

As shown in FIG. 1A, the image-forming optical system 101 forms an image of an external subject on the surface of the imaging device 102.

As shown in FIG. 1B, the imaging device 102 includes a plurality of pixels 103, 104, 105, . . . . The pixel 103 includes light receiving portions 106 and 107, the pixel 104 includes a light receiving portion 108, and the pixel 105 includes a light receiving portion 109 serving as signal acquisition units for acquiring ranging and correcting electrical signals. The pixels 103, 104, and 105 each include a reading unit (not shown) that converts electrical charge accumulated in each of the light receiving portions 106 to 109 to electrical signals and outputs the electrical signals to a distance calculation unit 111. The reading unit is constituted by, for example, a floating diffusion portion, a gate electrode, and wires.

As shown in FIG. 1C, the distance measuring apparatus 100 includes the distance calculation unit 111 for calculating a distance to the subject by using the acquired signals, in addition to the optical system 101 and the imaging device 102. The distance calculation unit 111 is constituted by a signal processing substrate including, for example, a CPU and a memory. The distance measuring apparatus 100 may have a recording unit 112 for recording read signals or calculation results. FIG. 1C illustrates the distance measuring apparatus 100; alternatively, it may be a digital camera including a driving mechanism for focusing of the optical system 101, a shutter, and a display, such as a liquid crystal display, for checking images.

The imaging device 102 that constitutes the distance measuring apparatus 100 of an embodiment of the present invention includes a signal acquisition unit that acquires, on a plurality of locations on the imaging device, a first electrical signal mainly based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction, a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction, and a third electrical signal different from the second electrical signal on the basis of a beam that has passed through a region eccentric from the first region in the direction opposite to the predetermined direction.

The calculation unit 111 performs a signal correction process for generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion and a distance calculation process for calculating the distance by using the first corrected signal.

These features will be described in detail later.

Definition of Center of Gravitation Angle, Center of Gravity of Pupil, and, Pupil Divided Region

In an embodiment of the present invention, the distance between the image-forming optical system 101 and the imaging device 102 is larger than the size of each pixel. This causes beams that have passed through different positions on an exit pupil 120 of the image-forming optical system 101 to be incident on the surface of the imaging device 102 at different incident angles.

The light receiving portions 106 and 107 receive beams from a predetermined angle range 121 depending on the shape of the exit pupil 120 and the positions of the light receiving portions 106 and 107 on the imaging device 102. The sensitivity characteristics of the light receiving portions 106 and 107 to the beams incident at different angles are referred to as angle characteristics.

An angle that is the center of gravity of the sensitivity of a light receiving portion in the angle range of a beam incident on the light receiving portion is referred to as a center-of-gravity angle. The center-of-gravity angle can be calculated by using Exp. 1.

In Exp. 1, θ is an angle that a pupil dividing direction (in this embodiment, the x-axis direction) forms with the z-axis in a plane including the z-axis, θg is the center-of-gravity angle, t(θ) is the sensitivity of the light receiving portion, and integration is performed on the angle range of beams incident on the light receiving portion.

[Math.  1] $\begin{matrix} {{\theta\; g} = \frac{\int_{\;}^{\;}{{{\sin(\theta)} \cdot {t(\theta)}}{\mathbb{d}\theta}}}{\int_{\;}^{\;}{{t(\theta)}{\mathbb{d}\theta}}}} & \left( {{Exp}.\mspace{14mu} 1} \right) \end{matrix}$

A position on the exit pupil 120 through which a beam incident on the light receiving portion at a center-of-gravity angle θg is referred to as the center of gravity of the pupil. A region on the exit pupil 120 which includes the center of gravity of the pupil and through which a beam incident from an angle range in which the sensitivity of the light receiving portion is high is referred to as a pupil divided region.

FIG. 2A shows the angle characteristics of the individual light receiving portions 106 to 109 to beams incident at different angles in the x-z plane, in which the horizontal axis indicates an angle that an incident beam forms with the x-axis in the x-z plane, and the vertical axis indicates the sensitivity. Reference signs 106 ga, 107 ga, 108 ga, and 109 ga denote the center-of-gravity angles of the light receiving portions 106, 107, 108, and 109, respectively.

Broken lines denoted by reference signs 106 t, 107 t, 108 t, and 109 t in FIG. 2B indicate regions through which the beams received by the light receiving portions 106, 107, 108, and 109, pass through, respectively. Reference signs 106 d, 107 d, 108 d, and 109 d denote the pupil divided regions of the light receiving portions 106, 107, 108, and 109, respectively. Reference signs 106 gp, 107 gp, 108 gp, and 109 gp denote the centers of gravity of the pupils of the light receiving portions 106, 107, 108, and 109, respectively.

The light receiving portions 106 and 107 are configured to have sensitivity to beams incident on the light receiving portions 106 and 107 in a wide angle range and to receive beams that have passed through the substantially whole regions 106 t and 107 t of the exit pupil 120.

The light receiving portion 106 is configured such that the pupil divided region 106 d is off the center of the exit pupil 120 in the +x direction. In other words, the light receiving portion 106 mainly receives a beam that has passed through a first region off the center of the exit pupil 120 in a predetermined direction. The light receiving portion 106 acquires a first electrical signal on the basis of the beam. Thus, the light receiving portion 106 constitutes a signal acquisition unit. The light receiving portion 106 can be referred to as a first light receiving portion.

The light receiving portion 107 is configured such that the pupil divided region 107 d is off-centered in the −x direction opposite to the pupil divided region 106 d. In other words, the light receiving portion 107 mainly receives a beam that has passed through a second region off the center of the exit pupil 120 in the direction opposite to the predetermined direction. The light receiving portion 107 acquires a second electrical signal on the basis of the beam. Thus, the light receiving portion 107 constitutes a signal acquisition unit. The light receiving portion 107 can be referred to as a second light receiving portion.

A direction in which the pupil divided regions 106 d and 107 d are connected is referred to as a pupil dividing direction (in this embodiment, the x-direction). The light receiving portions 106 and 107 are disposed at a plurality of locations in the pupil dividing direction on the imaging device 102. The light receiving portions 106 and 107 can receive beams that have passed through different pupil regions at the plurality of locations in the pupil dividing direction. Signals acquired by the light receiving portions 106 and 107 can be used as ranging signals or image signals.

The light receiving portion 108 is configured such that it has sensitivity to a beam that has passed through the pupil region 108 t in the pupil region 106 t and that the pupil divided region 108 d is eccentric from the pupil divided region 106 d to the −x direction (the direction opposite to the eccentric direction of the pupil divided region 106 d). In other words, the light receiving portion 108 acquires a third electrical signal different from the second electrical signal mainly on the basis of a beam that has passed through a region eccentric from the first region to the direction opposite to the predetermined direction. Thus, the light receiving portion 108 constitutes a signal acquisition unit. The light receiving portion 108 can be referred to as a third light receiving portion.

The light receiving portion 109 is configured such that it has sensitivity to a beam that has passed through the pupil region 109 t in the pupil region 107 t and that the pupil divided region 109 d is eccentric from the pupil divided region 107 d to the +x direction (the direction opposite to the eccentric direction of the pupil divided region 107 d). In other words, the light receiving portion 109 acquires a fourth electrical signal different from the first electrical signal mainly on the basis of the beam that has passed through a region eccentric from the second region in the predetermined direction. Thus, the light receiving portion 109 constitutes a signal acquisition unit. The light receiving portion 109 can be referred to as a fourth light receiving portion.

The light receiving portions 108 and 109 are disposed at a plurality of locations in the pupil dividing direction on the imaging device 102 and in the vicinity of the light receiving portions 106 and 107, respectively.

The signals acquired by the light receiving portions 106 to 109 can be used as correcting signals. The light receiving portion 108 is configured to receive beams more than the light receiving portion 107, and the light receiving portion 109 is configured to receive beams more than the light receiving portion 106 so that they have high sensitivity. Thus, the light receiving portions 106 to 108 can acquire correcting signals having a higher signal-to-noise (S/N) ratio than that of the ranging signals.

The signals acquired at the plurality of locations by the light receiving portions 106 to 108 are referred to as signals S₁₀₆, S₁₀₇, S₁₀₈, and S₁₀₉.

The distance calculation unit 111 calculates the distance to the subject in accordance with the flowchart shown in FIG. 3.

Step 131 is a signal correction process, in which a corrected signal CS₁₀₆ is generated by subtracting the signal S₁₀₈ from the signal S₁₀₆ at individual locations on the imaging device 102 in a predetermined proportion, as expressed as Exp. 2. In other words, the third electrical signal is subtracted from the first electrical signal in a predetermined proportion to generate a first corrected signal.

As expressed by Exp. 4, a corrected signal CS₁₀₇ is generated by subtracting the signal S₁₀₉ from the signal S₁₀₇ in a predetermined proportion at individual locations on the imaging device 102. In other words, the fourth electrical signal is subtracted from the second electrical signal in a predetermined proportion to generate a second corrected signal.

In Exp. 2 and Exp. 4, α and β are correction factors, which are real numbers larger than 0. Such a signal correction process is performed at a plurality of locations in the pupil dividing direction on the imaging device 120 to generate the corrected signals CS₁₀₆ and CS₁₀₇. CS ₁₀₆ =S ₁₀₆ −α·S ₁₀₈  (Exp. 2)

This can be simply expressed as Exp. 3. S ₁ ′=S ₁ −αS ₃  (Exp. 3) where S₁′ is the first corrected signal, S₁ and S₃ are the first and third electrical signals, and α is a correction factor. CS ₁₀₇ =S ₁₀₇ −β·S ₁₀₉  (Exp. 4)

This can be simply expressed as Exp. 5. S ₂ ′=S ₂ −βS ₄  (Exp. 5) where S₂′ is the second corrected signal, S₂ and S₄ are the second and fourth electrical signals, and β is a correction factor.

In step 132, the distance to the subject is calculated from the corrected signal CS₁₀₆ (first corrected signal) and corrected signal CS₁₀₇ (second corrected signal) pair. This includes a distance calculation process for calculating the distance by using the first corrected signal S₁′.

The gap length of the signal pair can be calculated using a known method. For example, the gap length can be obtained by calculating the correlation while shifting one of the signal pair to find a gap length at the highest correlation. Furthermore, a defocusing amount is obtained from the thus-acquired gap length by a known method to determine the distance to the subject.

Using the distance measuring apparatus 100 equipped with the light receiving portions 106 to 109 and the calculation unit described above allows the distance to a low-luminance subject to be measured with high accuracy.

Principle

The reason that high-accuracy ranging can be achieved by the distance measuring apparatus 100 of an embodiment of the present invention will be described.

The defocusing amount (distance) can be calculated from the gap length of the signal pair.

A gap length at a given defocusing amount depends on the base length. The base length depends on the distance between the centers of gravity of the pupils of light receiving portions that generate a signal pair.

The gap length increases as the distance between the centers of gravity of the pupils (base length) increases. This allows the gap length to be determined with high accuracy, thus enabling high-accuracy ranging.

In the signal correction process of step 131, the corrected signal CS₁₀₆ (first corrected signal) corresponds to a signal acquired by an imaginary light receiving portion having an angle characteristic 106 a′ that is obtained by subtracting the angle characteristic 108 a×α from the angle characteristic 106 a. This also applies to the corrected signal CS₁₀₇ (second corrected signal).

FIGS. 4A and 4B are graphs showing the angle characteristics of the light receiving portions 106 to 109 and the angle characteristics 106 a′ and 107 a′ of imaginary light receiving portions 106 a′ and 107 a′ corresponding to the corrected signal CS₁₀₆ (first corrected signal) and the corrected signal CS₁₀₇ (second corrected signal). FIG. 4C is a diagram illustrating the pupil divided regions 106 d, 106 d 7, 107 d, and 107 d′ and the centers of gravity of the pupils, 106 gp, 106 gp′, 107 gp, and 107 gp′.

As shown in FIG. 4A, the center-of-gravity angle 108 ga is smaller than the center-of-gravity angle 106 ga. Thus, the angle characteristic 106 a′ of the imaginary light receiving portion 106′ corresponding to the corrected signal CS₁₀₆ is such that the sensitivity particularly at a small angle is lower than that of the angle characteristic 106 a, as shown in FIG. 4B.

Thus, the center of the gravity angle 106 ga′ of the angle characteristic 106 a′ is larger to the + side than the center-of-gravity angle 106 ga. As shown in FIG. 4C, the pupil divided region 106 d′ corresponding to the corrected signal CS₁₀₆ is eccentric to the +x direction from the pupil divided region 106 d.

Also for the corrected signal CS₁₀₇, the center of the gravity angle 107 ga′ of the angle characteristic 107 a′ is larger to the − side than the center-of-gravity angle 107 ga, and the pupil divided region 107 d′ is eccentric to the −x direction from the pupil divided region 107 d.

The distance between the pupil divided regions 106 d′ and 107 d′ is lager than the distance between the pupil divided regions 106 d and 107 d before correction.

The distance 123 between the centers of gravity of the pupils 106 gp′ and 107 gp′ corresponding to the base length is larger than the base length 122 before correction. The gap length between the corrected signals CS₁₀₆ and CS₁₀₇ increases from that before correction, which allows the gap length to be obtained with high accuracy, thus allowing high-accuracy ranging. The distance measuring apparatus 100 of an embodiment of the present invention allows high-accuracy ranging of a low-luminance subject by using correcting signals with a high S/N ratio.

In the above-described signal correction process, if the correcting signals have noise (random noise), the corrected signals CS₁₀₆ and CS₁₀₇ are also given noise in a predetermined proportion in Exp. 3 or 5.

Insufficient S/N ratios of the corrected signals cause insufficient measurement accuracy of the image gap length.

This offsets the improving effect due to the image-gap-length increasing effect described above, thus reducing the ranging accuracy improving effect.

In particular, an extremely low-luminance subject causes much noise in the ranging signal S₁₀₆ (first electrical signal) and the ranging signal S₁₀₇ (second electrical signal).

Using a signal having a lower S/N ratio than that of a ranging signal as a correcting signal significantly increases an image-gap-length determination error, thus extremely reducing the improving effect of the signal correction process.

Thus, a correcting signal having a high S/N ratio or an S/N ratio higher than that of a ranging signal may be used.

In the distance measuring apparatus 100 of an embodiment of the present invention, the configurations of the signal acquisition units and the distance calculation unit 111 are not limited thereto.

The two light receiving portions 108 and 109 are provided as correcting signal acquisition units; alternatively, only the light receiving portion 108 may be provided, and signals acquired by the light receiving portion 108 may be used both as the correcting signals S₁₀₈ and S₁₀₉.

An example configuration in which a pupil is divided in the x-direction has been shown; alternatively, the pupil may be divided in the y-direction or in a slanting direction, and light receiving portions having pupil divided regions may be disposed in such a direction to perform ranging. This configuration allows ranging of a subject having different contrasts in such a direction.

An example in which the distance calculation unit 111 generates a pair of corrected signals CS₁₀₆ and CS₁₀₇ is shown above; alternatively, a corrected signal of one of the ranging signals S₁₀₆ and S₁₀₇ may be generated, and the corrected signal and the other ranging signal may be used to calculate the distance. This configuration can also provide the above advantages, thus allowing high-accuracy ranging.

Range of Correction Factor

In step 131 of FIG. 3, it is preferable that the correction factors α and β be within the ranges expressed by Exp. 6 and Exp. 8. In Exp. 6 and Exp. 8, t₁₀₆, t₁₀₇, t₁₀₈, and t₁₀₉ are the ratio of beams incident from locations on the exit pupil 120 to electrical signals converted by the individual light receiving portions 106 to 109.

Min( ) is a function for obtaining the minimum value in ( ),x and y are coordinates on the exit pupil 120, which are within the pupil region 108 t of the light receiving portion 108 in Exp. 6, and within the pupil region 109 t of the light receiving portion 109 in Exp. 8.

[Math.  2] $\begin{matrix} {0 < \alpha \leq {\min\left( \frac{t_{106}\left( {x,y} \right)}{t_{108}\left( {x,y} \right)} \right)}} & \left( {{Exp}.\mspace{14mu} 6} \right) \end{matrix}$

This can be simply expressed as Exp. 7. 0<α≦min[T ₁(p)/T ₃(p)]  (Exp. 7) where p is coordinates on the exit pupil 120, and T₁ and T₃ are the ratio of beams incident on the signal acquisition units from the coordinate positions on the exit pupil 120 to the first and third electrical signals S₁ and S₃ converted.

[Math.  3] $\begin{matrix} {0 < \beta \leq {\min\left( \frac{t_{107}\left( {x,y} \right)}{t_{109}\left( {x,y} \right)} \right)}} & \left( {{Exp}.\mspace{14mu} 8} \right) \end{matrix}$

This can be simply expressed as Exp. 9. 0<β≦min[T ₂(p)/T ₄(p)]  (Exp. 9) where p is coordinates on the exit pupil 120, and T₂ and T₄ are the ratio of beams incident on the signal acquisition units from the coordinate positions on the exit pupil 120 to the second and fourth electrical signals S₂ and S₄ converted.

Setting the correction factors α and β in this manner causes the angle characteristics 106 a′ and 107 a′ to have no negative sensitivity.

The light receiving portions 106 to 109 acquire, as signals, values obtained by integrating the beams incident thereon at different angles depending on the sensitivity.

If part of the angle characteristics has negative sensitivity, a beam received at negative sensitivity shows a negative value, and the negative value is offset with the value of a beam received with positive sensitivity. Thus, the corrected signal lacks information on part of the beams.

This causes an error in the gap length determined from the corrected signal, thus causing a ranging error. Setting the correction factors α and β within the ranges expressed by Exp. 6 and Exp. 8 can decrease the error in the corrected signal to reduce a gap length detection error, thus allowing higher-accuracy ranging.

Disposition of Light Receiving Portions

In the distance measuring apparatus 100 of an embodiment of the present invention, the light receiving portions 106 to 109 that acquire the ranging signals and the correcting signals may be disposed next to each other on the imaging device 102.

Disposing the light receiving portions 106 to 109 at separate positions causes beams coming from different subjects to be incident thereon. The difference among the incident beams causes errors in corrected signals generated from signals acquired by the light receiving portions 106 to 109 in the signal correction process, thus causing an error in the result of ranging.

The light receiving portions 106 to 109 may be disposed close to each other, within three pixels, or within the same pixel.

Distance Calculation Using Corrected Base Length

Calculating the distance using a corrected base length W′ in the distance calculation process in step 132 of FIG. 3 allows higher-accuracy ranging.

The corrected base length W′ can be obtained by calculating the distance 123 between the centers of gravity of the pupils 106 gp′ and 107 gp′ of the imaginary light receiving portions 106 d′ and 107 d′ corresponding to the corrected signals CS₁₀₆ and CS₁₀₇ in FIG. 4C (corrected-base-length calculation process).

First, the centers of gravity angles 106 ga′ and 107 ga′ are obtained from the angle characteristics of the light receiving portions 106 and 107 and the correction factors α and β, and the centers of gravity of the pupils 106 gp′ and 107 gp′ are calculated from the centers of gravity angles 106 ga′ and 107 ga′ and the positional information on the exit pupil 120.

Next, the distance 123 between the centers of gravity of the pupils 106 gp′ and 107 gp′ on the exit pupil 120 corresponding to the corrected base length W′ is calculated by using Exp. 10. W′=|106gp′−107gp′|  (Exp. 10)

The corrected base length 123 thus obtained and the gap length calculated in step 131 are used to obtain the defocusing amount by using Exp. 11, thereby calculating the distance to the subject.

In Exp. 11, ΔL is the defocusing amount, r is the gap length, L is the distance between the exit pupil 120 and the imaging device 102, and W′ is the corrected base length 123.

[Math.  4] $\begin{matrix} {{\Delta\; L} = \frac{rL}{w^{\prime} - r}} & \left( {{Exp}.\mspace{14mu} 11} \right) \end{matrix}$

By calculating the defocusing amount from the gap length by using a higher-accuracy base length, the distance can be calculated with higher accuracy.

In the distance calculation process of step 132, the distance may be calculated by another method.

For example, a transformation coefficient for connecting the gap length to the defocusing amount may be calculated in advance, and the calculated gap length and the transformation coefficient may be used to calculate the defocusing amount.

This can omit a calculation for calculating the base length depending on image-capturing conditions and the position of the light receiving portions on the image plane, thus allowing high-speed ranging.

Adjustment of Correction Factor

In the signal correction process of step 131, adjusting the correction factors α and β depending on the positions of the light receiving portions 106 to 109 on the imaging device 102 and image-acquisition conditions (correction-factor adjusting process) allows hither-accuracy ranging.

For the image-forming optical system 101 like a zoom lens, the distance from the exit pupil 120 to the imaging device 102 changes depending on the state of zooming. Eclipse due to changes in the aperture of the image-forming optical system 101 or the angle of view, if present, will change the shape of the exit pupil 120.

These changes will change the angle ranges of beams incident on the light receiving portions 106 to 109, thus changing the numerical ranges of the correction factors α and β in Exp. 6 and Exp. 8. Selecting optimum correction factors α and β depending on the positions of the light receiving portions 106 to 109 on the imaging device 102 and the image-acquisition conditions allow higher-accuracy ranging under the conditions.

Image Modification Process

The distance calculation unit of the distance measuring apparatus 100 according to an embodiment of the present invention may further perform a signal modification process for modifying the image form of the corrected signals CS₁₀₆ and CS₁₀₈.

The corrected signals CS₁₀₆ and CS₁₀₇ can be described using the light distribution f of the subject and corrected line spread functions L₁₀₆′ and L₁₀₇′, as in Exp. 12 and Exp. 13, where x is a position on the imaging device 102 in the pupil dividing direction.

[Math.  5] $\begin{matrix} {{{CS}_{106}\lbrack x\rbrack} = {\sum\limits_{- \infty}^{+ \infty}{{f\left\lbrack {x - i} \right\rbrack}{L_{106}^{\prime}\lbrack i\rbrack}}}} & \left( {{Exp}.\mspace{14mu} 12} \right) \\ \left\lbrack {{Math}.\mspace{14mu} 6} \right\rbrack & \; \\ {{{CS}_{107}\lbrack x\rbrack} = {\sum\limits_{- \infty}^{+ \infty}{{f\left\lbrack {x - i} \right\rbrack}{L_{107}^{\prime}\lbrack i\rbrack}}}} & \left( {{Exp}.\mspace{14mu} 13} \right) \end{matrix}$

Let L₁₀₆, L₁₀₇, L₁₀₈, and L₁₀₉ be line spread functions determined depending on the point spread function of the image-forming optical system 101, the angle characteristics of the light receiving portions 106 to 109, and the shape and position of the exit pupil 120.

Corrected line spread functions L₁₀₆′ and L₁₀₇′ in Exp. 12 and Exp. 13 can be described as in Exp. 14 and Exp. 16, where α and β are the correction factors used in step 131. L′ ₁₀₆ [x]=L ₁₀₆ [x]−αL ₁₀₈ [x]  (Exp. 14)

This can be further simplified to Exp. 15. L ₁ ′=L ₁ −αL ₃  (Exp. 15) where L₁′ can be referred to as a first modification filter, and L₁ and L₃ can be referred to as line spread functions determined depending on the signal acquisition units for the first and third electrical signals S₁ and S₃ and the optical system 101. L′ ₁₀₇ [x]=L ₁₀₇ [x]−βL ₁₀₉ [x]  (Exp. 16)

This can be further simplified to Exp. 17. L ₂ ′=L ₂ −βL ₄  (Exp. 17) where L₂′ can be referred to as a second modification filter, and L₂ and L₄ can be referred to as line spread functions determined depending the signal acquisition units for the second and fourth electrical signals S₂ and S₄ and the optical system 101.

The line spread function L is determined depending on the position and shape of the exit pupil 120 and the angle characteristics of the light receiving portions 106 to 109. Eclipse due to the lens frame of the image-forming optical system 101, is possible, will make the line spread functions L₁₀₆ and L₁₀₇ differ from each other and the line spread functions L₁₀₈ and L₁₀₉ differ from each other.

The corrected line spread functions L₁₀₆′ and L₁₀₇′ differ from each other, and the image shapes of the corrected signals CS₁₀₆′ and CS₁₀₇′ differ from each other.

Next, a flowchart including the signal modification process will be shown in FIG. 5.

FIG. 5 is a flowchart similar to FIG. 3 but differs from FIG. 3 in that it has a signal modification processing step 133.

Step 133 is a signal modification process for modifying the image shapes of the corrected signals CS₁₀₆ and CS₁₀₇.

First, a temporary defocusing amount is calculated from the pair of signals S₁₀₆ and S₁₀₇ or the corrected signals CS₁₀₆ and CS₁₀₇ using a known unit.

Next, the corrected line spread functions L₁₀₆′ and L₁₀₇′ shown in Exp. 14 and Exp. 16 are created as image modification filters on the basis of the temporary defocusing amount and the known information about the angle characteristics of the individual light receiving portions 106 to 109 and the known information on the exit pupil 120.

The corrected signals CS₁₀₆ and CS₁₀₇ are subjected to convolution integral by the image modification filters L₁₀₇′ and L₁₀₆′ to create a modified signal MS₁₀₆ (first modified signal) and a modified signal MS₁₀₇ (second modified signal), respectively. The reference point for the convolution integral is set at the centers of weight of the image modification filters L₁₀₇′ and L₁₀₆′.

The image shapes of the modified signals MS₁₀₆ and MS₁₀₇ are expressed as Exp. 18 and Exp. 19.

     [Math.  7] $\begin{matrix} {{{MS}_{106}\lbrack x\rbrack} = {{\sum\limits_{i = 0}^{m}{{{CS}_{106}\left\lbrack {x - i} \right\rbrack}{L_{107}^{\prime}\lbrack i\rbrack}}} = {\sum\limits_{j = 0}^{n}{\sum\limits_{i = 0}^{m}{{f\left\lbrack {x - i - j} \right\rbrack}{L_{106}^{\prime}\lbrack i\rbrack}{L_{107}^{\prime}\lbrack j\rbrack}}}}}} & \left( {{Exp}.\mspace{14mu} 18} \right) \\ {\mspace{79mu}\left\lbrack {{Math}.\mspace{14mu} 8} \right\rbrack} & \; \\ {{{MS}_{107}\lbrack x\rbrack} = {{\sum\limits_{i = 0}^{m}{{{CS}_{107}\left\lbrack {x - i} \right\rbrack}{L_{106}^{\prime}\lbrack i\rbrack}}} = {\sum\limits_{i = 0}^{m}{\sum\limits_{j = 0}^{n}{{f\left\lbrack {x - j - i} \right\rbrack}{L_{107}^{\prime}\lbrack j\rbrack}{L_{106}^{\prime}\lbrack i\rbrack}}}}}} & \left( {{Exp}.\mspace{14mu} 19} \right) \end{matrix}$

As shown in Exp. 18 and Exp. 19, the image shapes of the modified signals MS₁₀₆ and MS₁₀₇ are determined depending on the corrected line spread functions L₁₀₆′ and L₁₀₇′ and are substantially the same.

In step 132, the defocusing amount and the distance to the subject are calculated using the modified signals MS₁₀₆ and MS₁₀₇ by a known unit.

The ranging calculation including the signal modification process according to an embodiment of the invention allows the image shapes of the corrected signals CS₁₀₆ and CS₁₀₇ to be modified, thus reducing gap-length calculation errors due to a difference in image shape. This can improve the gap length determination accuracy, allowing higher-accuracy ranging.

The image modification filters L₁₀₆′ and L₁₀₇′ are functions that change depending on the defocusing amount.

An image modification filter may be created again on the basis of the defocusing amount obtained in step 132, and the image modification filter may be used to create a modified image to find a defocusing amount.

Creating the image modification filter on the basis of a defocusing amount closer to a correct value reduces the shape error of the image modification filter. This reduces the shape error of the modified signals MS₁₀₆ and MS₁₀₇, which improves the accuracy of calculation of the gap length and the defocusing amount, thus improving the ranging accuracy.

The signal modification process is not limited to that of this embodiment. For example, the signal modification process may be performed by deriving inverse functions L₁₀₆′−1 and L₁₀₇′−1 of the corrected line spread functions L₁₀₇′ and L₁₀₆′ in Exp. 14 and Exp. 16 and by performing convolution integral on the corrected signals CS₁₀₆ and CS₁₀₇ by the inverse functions L₁₀₆′−1 and L₁₀₇′−1.

This description shows a process example in which the signal modification process uses one-dimensional line spread functions in the pupil dividing direction (x-direction); alternatively, a two-dimensional point spread function (x-y direction) may be used for the modification. This allows a modification process considering a direction (y-direction) perpendicular to the pupil dividing direction caused by defocusing, thus allowing higher-accuracy modified signals to be created. Alternatively, another signal modification process may be performed on the basis of the information on the exit pupil 120 and the characteristics of the signal acquisition units.

Image-Acquisition System, AF, and Distance Image

The result of ranging of the distance measuring apparatus 100 of an embodiment of the present invention can be used, for example, to detect the focus of the image-forming optical system 101. The distance measuring apparatus 100 of an embodiment of the present invention allows the distance to the subject to be measured at high speed and with high accuracy, thus allowing the gap length between the subject and the focal position of the image-forming optical system 101 to be determined. Controlling the focal position of the image-forming optical system 101 allows the focal position to coincide with the subject at high speed and with high accuracy.

Alternatively, disposing such light receiving portions all over the imaging device 102 and calculating the distance using signals acquired for a plurality of regions on the imaging device 102 allows a distance image to be acquired.

The distance measuring apparatus 100 of an embodiment of the present invention can constitute image acquisition units, such as a digital still camera and a digital video camera, and the focus of the optical system 101 can be detected on the basis of the distance measurement result of the distance measuring apparatus 100.

Other Configurations

Specific examples of the imaging device of the distance measuring apparatus 100 of an embodiment of the present invention include solid-state imaging devices, such as a CMOS sensor (complementary metal-oxide semiconductor sensor) and a charge-coupled device (CCD) sensor.

The calculation unit 111 of the distance measuring apparatus 100 can be constituted by an integrated circuit in which semiconductor devices are integrated; for example, an integrated circuit (IC), a large scale integrated circuit (LSI), a system LSI, a microprocessing unit (MPU), and a central processing unit (CPU).

The present invention further includes a program in addition to the distance measuring apparatus 100.

A program according to an embodiment of the present invention causes a computer for calculating, in a distance measuring apparatus including an optical system forming an image of a subject and an imaging device acquiring an electrical signal from a beam that has passed through an exit pupil of the optical system, a distance to a subject by using a first electrical signal mainly based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction, a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction, and a third electrical signal different from the second electrical signal, the third electrical signal being based on a beam that has passed through a region eccentric from the first region in the direction opposite to the predetermined direction, to execute predetermined processes.

Here, the distance measuring apparatus 100 shown in FIG. 1C includes the optical system 101, the imaging device 102, the calculation unit 111, and the recording unit 112.

The calculation unit 111 constituted by a microprocessing unit, a central processing unit, or the like can be regarded as a computer.

A program according to an embodiment of the present invention causes the computer corresponding to the calculation unit to execute a signal correction process for generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion and a distance calculation process for calculating the distance by using the first corrected signal.

The program according to an embodiment of the present invention allows a distance measuring apparatus or an image-acquisition unit to perform high-accuracy ranging by being installed in a computer of a distance measuring apparatus or an image-acquisition unit, such as a camera, including a predetermined image-forming optical system, a predetermined imaging device, and the computer.

The program of an embodiment of the present invention can be distributed via the Internet, in addition to a recording medium.

Embodiments of the present invention can also be realized by a computer of a system or apparatus that reads out and executes computer executable instructions recorded on a storage medium (e.g., non-transitory computer-readable storage medium) to perform the functions of one or more of the above-described embodiments of the present invention, and by a method performed by the computer of the system or apparatus by, for example, reading out and executing the computer executable instructions from the storage medium to perform the functions of one or more of the above-described embodiments. The computer may comprise one or more of a central processing unit (CPU), microprocessing unit (MPU), or other circuitry, and may include a network of separate computers or separate computer processors. The computer executable instructions may be provided to the computer, for example, from a network or the storage medium. The storage medium may include, for example, one or more of a hard disk, a random-access memory (RAM), a read only memory (ROM), a storage of distributed computing systems, an optical disk (such as a compact disc (CD), digital versatile disc (DVD), or Blu-ray Disc (BD)™), a flash memory device, a memory card, and the like.

The present invention will be described in detail below with reference to specific examples.

First Embodiment

Example configurations of signal acquisition units of the distance measuring apparatus 100 according to a first embodiment of the present invention will be shown in FIG. 6.

In FIG. 6, the light receiving portions 106 and 107 are configured such that a microlens 210 is provided in the pixel 103 and photoelectric conversion sections 206 and 207 are provided in a substrate 201 formed of a semiconductor or the like.

The light receiving portions 108 and 109 are configured such that a microlens 211 is provided in each of the pixels 104 and 105, and photoelectric conversion sections 208 and 209 are provided in the semiconductor substrate 201, respectively. The pixels 103 to 105 each include a reading unit (not shown) that outputs electrical charge, as electrical signals, accumulated in the individual light receiving portions 106 to 109 to the distance calculation unit 111.

Beams that have passed through the exit pupil 120 and are incident on the light receiving portions 106 to 109 pass through the microlens 210 or 211 and are guided to the photoelectric conversion sections 206 to 209, respectively.

In the light receiving portions 106 and 107, beams 202 and 203 that have passed through the pupil divided regions 106 d and 107 d having different exit pupils 120 (FIG. 2B) are particularly efficiently received by the photoelectric conversion section 206 and the photoelectric conversion section 207, respectively.

This configuration can easily achieve the light receiving portions 106 and 107 having the high-sensitivity pupil divided regions 106 d and 107 d (FIG. 2B) that are eccentric in different directions on the exit pupil 120 (FIG. 1A).

The light receiving portions 108 and 109 efficiently receive beams 204 and 205 that have passed through the pupil divided regions 108 d and 109 d in the vicinity of the center of the exit pupil 120 (FIG. 2B) with photoelectric conversion sections 208 and 209, respectively.

This configuration can easily achieve the light receiving portions 108 and 109 that mainly receive beams coming from the pupil divided regions 108 d and 109 d eccentric from the pupil divided regions 106 d and 107 d in the opposite direction, respectively. This configuration can easily achieve the light receiving portions 108 and 109 having higher sensitivity than the light receiving portions 106 and 107. Adjusting the curvatures of the microlens 210 and 211 and the distances to the photoelectric conversion sections 206 to 209 allows control of the angle characteristics and the pupil divided regions 106 d to 109 d of the light receiving portions 106 to 109. This configuration allows ranging signals to be obtained from the light receiving portions 106 and 107 and correcting signals to be obtained from the light receiving portions 108 and 109, and the distance to be calculated by the distance calculation unit 111 described above.

In the distance measuring apparatus 100 of an embodiment of the present invention, the configuration in which a plurality of photoelectric conversion sections are disposed in a pixel, like the pixel 103, allows beams to be received with high sensitivity by the photoelectric conversion sections 206 and 207, thus allowing high-quality image signals to be acquired. The signals acquired by the light receiving portions 108 and 109 can be used as image signals for the pixels 104 and 105, respectively.

Other example configurations of the light receiving portions 106 to 109 constituting the distance measuring apparatus 100 of the first embodiment will be shown in FIGS. 7A and 7B.

Referring to FIG. 7A, the light receiving portions 106 and 107 are disposed in different pixels 220 and 221, respectively.

The light receiving portions 106 and 107 each include the microlens 210, a photoelectric conversion section 222 or 223, and a light shield 224 or 225. The light receiving portions 108 and 109 have the same configuration as that in FIG. 6. The pixels 222 and 223 each include a reading unit (not shown) that outputs electrical charge, as electrical signals, accumulated in the light receiving portions 106 and 107 to the distance calculation unit 111.

The photoelectric conversion sections 222 and 223 of the light receiving portions 106 and 107 receive beams that have passed through the exit pupil 120. The light receiving portion 106 blocks the beam 203 and mainly receives the beam 202. The light receiving portion 107 blocks the beam 202 and mainly receives the beam 203.

This configuration allows the ranging signals signal S₁₀₆ and S₁₀₇ to be acquired. The correcting signals S₁₀₈ and S₁₀₉ can be acquired by the light receiving portions 108 and 109, respectively, as in the above.

Using these signals allows high-accuracy ranging with the above-described method. This configuration can increase the distance between the photoelectric conversion sections 222 and 223, thus making it easy to manufacture the light receiving portions 106 and 107 of an imaging device having small pixels.

Waveguide Type

The pixels 103 to 105 constituting the distance measuring apparatus 100 may each include a waveguide shown in FIG. 8.

The pixels 103 to 105 each include a waveguide composed of a core 230 and a clad 231 at the light incident side (+z side) of the substrate 201. The pixel 103 includes the photoelectric conversion sections 206 and 207. The pixels 104 and 105 include the photoelectric conversion sections 208 and 209, respectively. The pixels 103 to 105 each include a reading unit (not shown) that outputs electrical charge, as electrical signals, accumulated in the light receiving portions 106 to 109 to the distance calculation unit 111.

The core 230 and the clad 231 are formed of a transparent material having an imaging wavelength range. The core 230 is formed of a material having a higher refractive index than that of the clad 231.

This allows light to be enclosed and propagated in the core 230. The beams that have passed through the exit pupil 120 and are incident on the individual pixels 103 to 105 propagate through the waveguides to the photoelectric conversion sections 206 to 209.

In the pixel 103, the beam 202 is particularly efficiently received by the photoelectric conversion section 206, and the beam 203 is particularly efficiently received by the photoelectric conversion section 207. In the pixels 104 and 105, the beams 204 and 205 are efficiently received by the photoelectric conversion sections 208 and 209, respectively.

This configuration allows incident light to be efficiently received also with an imaging device having small pixel size.

Alternatively, a back-illuminated type in which a waveguide composed of a core and a clad is provided in the substrate 104 is possible.

This configuration allows light incident from the back of the substrate 104 (light propagating in the +z direction) to be detected. Wires and so on can be disposed on the front of the substrate 104, thus preventing interference with propagation of incident light due to the wires and so on. Furthermore, this configuration reduces spatial restriction due to the wires and so on, thus allowing incident light to be efficiently guided to the photoelectric conversion sections 206 to 209.

Second Embodiment

An example configuration of a signal acquisition unit of the distance measuring apparatus 100 according to a second embodiment will be shown in FIGS. 9A to 9C.

In FIG. 9A, an imaging device 200 includes the pixels 103 each including the light receiving portion 106 and the light receiving portion 107.

The light receiving portions 106 and 107 have the same configuration as shown in FIG. 6.

The pixels 103 each include a reading unit (not shown) that converts electrical charge accumulated in the light receiving portions 106 and 107 to electrical signals and outputs the signals to the distance calculation unit 111 (FIG. 1C).

The second embodiment uses the electrical signals acquired by the light receiving portions 106 and 107 as the ranging signals S₁₀₆ and S₁₀₇.

FIGS. 9B and 9C are diagrams showing the angle characteristics of the light receiving portions 106 and 107 and the pupil divided regions 106 d and 107 d on the exit pupil 120.

The light receiving portions 106 and 107 generate a signal (in the second embodiment, referred to as an added signal S₂₅₀) based on a beams that has mainly passed through a region 250 d including the pupil divided regions 106 d and 107 d. For example, the added signal S₂₅₀ is generated by adding the ranging signals S₁₀₆ and S₁₀₇ acquired by the light receiving portions 106 and 107, respectively. Alternatively, the added signal S₂₅₀ is generated by the reading unit on the basis of the amount of electrical charge accumulated in the light receiving portions 106 and 107. The added signal S₂₅₀ is used as a correcting signal of the ranging signal S₁₀₆ or S₁₀₇.

Ranging by the above method using these signals allows a low-luminance subject to be measured with high accuracy.

The pupil region 250 d has its center of gravity 250 ga between the centers of gravity 106 ga and 107 ga of the pupil divided regions 106 d and 107 d.

The pupil region 250 d is a region eccentric to the direction opposite to the eccentric direction of the pupil region 106 d in which the added signal S₂₅₀ can be used as a correcting signal for the ranging signal S₁₀₆. The pupil region 250 d is also a region eccentric to the direction opposite to the eccentric direction of the pupil region 107 d, in which the added signal S₂₅₀ can be used as a correcting signal for the ranging signal S₁₀₇.

The added signal S₂₀₅ includes the signal components of the ranging signals S₁₀₆ and S₁₀₇, that is, twice the ranging signals S₁₀₆ and S₁₀₇. The noise component thereof is smaller than the twice, because the random noises of the ranging signals S₁₀₆ and S₁₀₇ are averaged. In other words, the S/N ratio of the added signal S₂₅₀ is higher than the S/N ratios of the individual signals S₁₀₆ and S₁₀₇.

Using such a correcting signal for the signal correction process can suppress a drop in the S/N ratios of the corrected signals, thus allowing high-accuracy ranging of a low-luminance subject, as in the above.

Generating the signals from the electrical signals S₁₀₆ and S₁₀₇ acquired by the light receiving portions 106 and 107 eliminates the need for a light receiving portion for acquiring a correcting signal, thus simplifying the configuration.

Furthermore, this configuration allows the ranging signals S₁₀₆ and S₁₀₇ and the correcting signal S₂₅₀ to be acquired at the same pixel, and errors in the corrected signal CS₁₀₆ and CS₁₀₇ to be reduced for the above reason, thus allowing higher-accuracy ranging.

Disposing such pixels 103 all over the imaging device 102 allows a high-resolution and high-accuracy distance image and a high-quality image to be acquired at the same time.

In the distance measuring apparatus 200 of the second embodiment of the present invention, the configuration of the light receiving portions 106 and 107 is not limited thereto.

The pixels 220 and 221 shown in FIGS. 7A and 7B or the pixel 103 shown in FIG. 8 may be disposed all over the imaging device 102, and the electrical signals acquired by the light receiving portions 106 and 107 included in the pixels 220 and 221 or the pixels 103 to 105 may be used as ranging signals and correcting signals. This can provide the same advantages as those described above.

Third Embodiment

Example configurations of signal acquisition units of the distance measuring apparatus 100 according to a third embodiment will be shown in FIG. 10.

An imaging device 300 shown in FIG. 10 includes pixels 220 and the pixels 104. The pixels 220 each include the light receiving portion 106, and the pixels 104 each include the light receiving portion 108.

The angle characteristics and the pupil divided regions 106 d and 108 d of the light receiving portions 106 and 108 are the same as above. The pixels 220 and 104 each include a reading unit (not shown) that outputs electrical charge, as electrical signals, accumulated in the light receiving portions 106 and 108 to the distance calculation unit 111.

The third embodiment uses a signal acquired by the light receiving portion 106 (first light receiving portion) as the ranging signal S₁₀₆ (first electrical signal) and a signal obtained by subtracting the ranging signal S₁₀₆ from a signal acquired by the light receiving portion 108 as the ranging signal S₁₀₇ (second electrical signal). The third embodiment uses the signal acquired by the light receiving portion 108 as a correcting signal for the ranging signal S₁₀₆ or S₁₀₇. Thus, the light receiving portion 108 can be referred to as a fifth light receiving portion.

Ranging by the above method using these signals allows a low-luminance subject to be measured with high accuracy. The light receiving portion 108 is configured to receive beams more than the light receiving portion 106 to have high sensitivity, as described above, thus allowing correcting signals having a high S/N ratio to be acquired.

Such a configuration can reduce the number of light receiving portions for acquiring ranging signals and correcting signals, thus simplifying the configuration of the imaging device 102. In particular, using the light receiving portion 108 having higher sensitivity than the light receiving portion 107 can improve the quality of the signals, thus enhancing the image quality, as compared with the configuration in FIGS. 7A and 7B.

REFERENCE SIGNS LIST

100 distance measuring apparatus

101 optical system

102 imaging device

111 calculation unit

120 exit pupil

While the present invention has been described with reference to exemplary embodiments, it is to be understood that the invention is not limited to the disclosed exemplary embodiments. The scope of the following claims is to be accorded the broadest interpretation so as to encompass all such modifications and equivalent structures and functions.

This application claims the benefit of Japanese Patent Application No. 2012-248624, filed Nov. 12, 2012, which is hereby incorporated by reference herein in its entirety. 

The invention claimed is:
 1. A distance measuring apparatus comprising: an optical system forming an image of a subject; an imaging device acquiring an electrical signal from a beam that has passed through an exit pupil of the optical system; and a calculation unit calculating a distance to the subject on the basis of the electrical signal, wherein the imaging device includes a signal acquisition unit acquiring a first electrical signal mainly based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction; a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction; and a third electrical signal different from the second electrical signal on the basis of a beam that has passed through a third region off the first region in the direction opposite to the predetermined direction, and wherein the calculation unit performs a signal correction process for generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion and a distance calculation process for calculating the distance by using the first corrected signal in a phase-difference detection method.
 2. The distance measuring apparatus according to claim 1, wherein, in the signal correction process, the first corrected signal is generated on the basis of Exp. 3, S ₁ ′=S ₁ −αS ₃  (Exp. 3) where S₁′ is the first corrected signal, S₁ is the first electrical signal, S₃ is the third electrical signal, and α is a positive value that causes S1′ to have no negative value.
 3. The distance measuring apparatus according to claim 1, wherein the signal acquisition unit further acquires a fourth electrical signal different from the first electrical signal mainly on the basis of a beam that has passed through a forth region off the second region to the predetermined direction; in the signal correction process, a second corrected signal is further generated by subtracting the fourth electrical signal from the second electrical signal in a predetermined proportion; and in the distance calculation process, the distance is calculated using the first corrected signal and the second corrected signal.
 4. The distance measuring apparatus according to claim 3, wherein, in the signal correction process, the second corrected signal is generated on the basis of Exp. 5, S ₂ ′=S ₂ −βS ₄  (Exp. 5) where S₂′ is the second corrected signal, S₂ is the second electrical signal, S₄ is the fourth electrical signal, and β is a positive value that causes S2′ to have no negative value.
 5. The distance measuring apparatus according to claim 3, wherein the signal acquisition unit generates electric signals in accordance with a quantity of a beam; the third electrical signal is a signal having a higher S/N ratio than the S/N ratio of the second electrical signal; and the fourth electrical signal is a signal having a higher S/N ratio than the S/N ratio of the first electrical signal.
 6. The distance measuring apparatus according to claim 3, wherein the signal acquisition unit includes first, second, third, and fourth light receiving portions that acquires the first, second, third, and fourth electrical signals, respectively.
 7. The distance measuring apparatus according to claim 1, wherein the third electrical signal is an electrical signal different from the second electrical signal, the third electrical signal being acquired mainly on the basis of, among beams that have passed through a pupil region through which a beam corresponding to the first electrical signal passes, a beam that has passed through the third region off the first region in the direction opposite to the predetermined direction.
 8. The distance measuring apparatus according to claim 3, wherein the fourth electrical signal is an electrical signal different from the first electrical signal, the fourth electrical signal being acquired mainly on the basis of, among beams that have passed through a pupil region through which a beam corresponding to the second electrical signal passes, a beam that has passed through the forth region off the second region to the predetermined direction.
 9. The distance measuring apparatus according to claim 3, wherein the signal acquisition unit includes first and second light receiving portions acquiring the first and second electrical signals, respectively; and the third and fourth electrical signals are generated by the first and second light receiving portions mainly on the basis of beams that have passed through the first region and the second region, respectively.
 10. The distance measuring apparatus according to claim 3, wherein the signal acquisition unit includes a first light receiving portion and a fifth light receiving portion; the third and fourth electrical signals are acquired by the fifth light receiving portion; the first electrical signal is acquired by the first light receiving portion; and the second electrical signal is a signal generated by subtracting the first electrical signal from the electrical signal acquired by the fifth light receiving portion.
 11. The distance measuring apparatus according to claim 6, wherein the imaging device includes a plurality of pixels having the light receiving portions; and the light receiving portions are disposed in three adjacent pixels.
 12. The distance measuring apparatus according to claim 3, wherein the calculation unit further performs a corrected-base-length calculation process for calculating a corrected base length on the basis of regions on the exit pupil through which beams corresponding to the first and second corrected signals pass; and in the distance calculation process, the distance is calculated using the correct base length and the corrected signal.
 13. The distance measuring apparatus according to claim 4, wherein the signal correction process includes a correction-factor adjusting process for adjusting the correction factors depending on the shape of the exit pupil, the distance between the exit pupil and the imaging device, or positions on the imaging device.
 14. The distance measuring apparatus according to claim 4, wherein the calculation unit further performs a signal modification process for generating first and second modification filters expressed by Exp. 15 and Exp. 17 and performing convolution integral of the first corrected signal and the second modification filter and convolution integral of the second corrected signal and the first modification filter to generate a first modified signal and a second modified signal, respectively; and the distance calculation process is a process for calculating the distance by using the first modified signal and the second modified signal instead of the first corrected signal and the second corrected signal, L ₁ ′=L ₁ −αL ₃  (Exp. 15) L ₂ ′=L ₂ −βL ₄  (Exp. 17) where L₁′ and L₂′ are the first and second modification filters, L₁, L₂, L₃, and L₄ are line spread functions determined depending on the signal acquisition units for the first, second, third, and fourth signals and the optical system, and α and β are the correction factors.
 15. An image acquisition unit comprising the distance measuring apparatus according to claim
 1. 16. The image acquisition unit according to claim 15, wherein the distance measuring apparatus detects the focus of the optical system on the basis of the result of distance measurement of the distance measuring apparatus.
 17. The image acquisition unit according to claim 15, wherein the image acquisition unit acquires a distance image by using the distance measuring apparatus.
 18. A method for measuring a distance, comprising the steps of: acquiring a first electrical signal mainly based on a beam that has passed through a first region off the center of an exit pupil of an optical system in a predetermined direction; acquiring a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction; acquiring a third electrical signal different from the second electrical signal on the basis of a beam that has passed through a third region off the first region in the direction opposite to the predetermined direction; generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion; and calculating the distance by using the first corrected signal in a phase-difference detection method.
 19. A non-transitory storage medium recording a program for causing a computer for calculating, in a distance measuring apparatus including an optical system forming an image of a subject and an imaging device acquiring an electrical signal from a beam that has passed through an exit pupil of the optical system, a distance to a subject by using a first electrical signal mainly based on a beam that has passed through a first region off the center of the exit pupil in a predetermined direction, a second electrical signal mainly based on a beam that has passed through a second region off the center of the exit pupil in a direction opposite to the predetermined direction, and a third electrical signal different from the second electrical signal, the third electrical signal being based on a beam that has passed through a third region off the first region in the direction opposite to the predetermined direction, to execute a signal correction process for generating a first corrected signal by subtracting the third electrical signal from the first electrical signal in a predetermined proportion and a distance calculation process for calculating the distance by using the first corrected signal in a phase-difference detection method. 